package com.witmed.lib_base

import android.app.Application
import android.util.Log
import io.reactivex.Observer
import io.reactivex.disposables.Disposable


abstract class BaseOBViewModel<T:BaseModel>:BaseViewModel<T>(),
    Observer<BaseEntity> {


    override fun onSubscribe(p0: Disposable) {
        addCompositeDisposable(p0)
        showDialog()

    }

    override fun onComplete() {
        hiddenDialog()
    }

    override fun onError(p0: Throwable) {
        showMsg(p0.message!!)
    }
}